<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
 <%@taglib prefix="s" uri="/struts-tags"%>
 <%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<base href="<%=basePath%>">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Insert title here</title>
</head>
<body>
<div class="container">
    <div class="panel panel-default">
        <div class="panel-heading">
            <div class="panel-title">
				<h3 class="text-center">明细订单</h3>
            </div>
        </div>
		
		<s:set id="sum_price" value="0" />
						<table class="table table-bordered text-center table-hover">
							<thead>
									<tr>
										<th class="text-center">明细订单编号</th>
										<th class="text-center">书名</th>
										<th class="text-center">租赁数量</th>
										<th class="text-center">租赁单价(元)</th>
									</tr>
							</thead>
						
							<tbody>
							
								<s:iterator id="var_order" value="#request.orderDetailList">
									<tr>
										<td>${var_order.ordersAttachId}</td>
										<td>${var_order.foods.foodName}</td>
										<td>${var_order.foodCount}</td>
										<td>${var_order.orderPrice}</td>
										<s:set id="sum_price" value="#sum_price + #var_order.orderPrice" />
									</tr>
								</s:iterator>
								
							</tbody>
						
								
							
						</table>
						<h4 class="text-center ">总金额${sum_price }元</h4>
						<ul class="nav nav-pills nav-justified">
							<li class="bg-info"><a href="javaScript:history.back()"><h3>返回</h3></a></li>
						</ul>

</div>
</div>
</body>
</html>